diff --git a/qcom/qrtr/lib/libqrtr.h b/qcom/qrtr/lib/libqrtr.h
index 87433ed..93254df 100644
--- a/qcom/qrtr/lib/libqrtr.h
+++ b/qcom/qrtr/lib/libqrtr.h
@@ -4,6 +4,7 @@
 #include <linux/qrtr.h>
 #include <sys/types.h>
 #include <sys/socket.h>
+#include <stddef.h>
 #include <stdint.h>
 
 #ifdef __cplusplus
@@ -11,7 +12,7 @@
 #endif
 
 #ifndef offsetof
-#define offsetof(type, md) ((unsigned long)&((type *)0)->md)
+#define offsetof(type, md) ((size_t)&((type *)0)->md)
 #endif
 
 #ifndef container_of
@@ -90,7 +91,7 @@
 	uint32_t elem_size;
 	enum qmi_array_type array_type;
 	uint8_t tlv_type;
-	uint32_t offset;
+	size_t offset;
 	struct qmi_elem_info *ei_array;
 };
 
diff --git a/qcom/qrtr/lib/qmi.c b/qcom/qrtr/lib/qmi.c
index f1c0293..d217a2d 100644
--- a/qcom/qrtr/lib/qmi.c
+++ b/qcom/qrtr/lib/qmi.c
@@ -249,8 +249,8 @@
 			LOGW("%s: STRUCT Encode failure\n", __func__);
 			return rc;
 		}
-		buf_dst = (char*)buf_dst + rc;
-		buf_src = (char*)buf_src + temp_ei->elem_size;
+		buf_dst = (void*)((char*)buf_dst + rc);
+		buf_src = (void*)((char*)buf_src + temp_ei->elem_size);
 		encoded_bytes += rc;
 	}
 
@@ -310,7 +310,7 @@
 		encoded_bytes += rc;
 	}
 
-	rc = qmi_encode_basic_elem((char*)buf_dst + encoded_bytes, buf_src,
+	rc = qmi_encode_basic_elem((void*)((char*)buf_dst + encoded_bytes), buf_src,
 				   string_len, temp_ei->elem_size);
 	encoded_bytes += rc;
 
@@ -354,7 +354,7 @@
 		buf_dst = buf_dst + (TLV_LEN_SIZE + TLV_TYPE_SIZE);
 
 	while (temp_ei->data_type != QMI_EOTI) {
-		buf_src = (char*)in_c_struct + temp_ei->offset;
+		buf_src = (void*)((char*)in_c_struct + temp_ei->offset);
 		tlv_type = temp_ei->tlv_type;
 
 		if (temp_ei->array_type == NO_ARRAY) {
@@ -522,8 +522,8 @@
 				tlv_len - decoded_bytes, dec_level);
 		if (rc < 0)
 			return rc;
-		buf_src = (char*)buf_src + rc;
-		buf_dst = (char*)buf_dst + temp_ei->elem_size;
+		buf_src = (void*)((char*)buf_src + rc);
+		buf_dst = (void*)((char*)buf_dst + temp_ei->elem_size);
 		decoded_bytes += rc;
 	}
 
@@ -585,7 +585,7 @@
 		return -EFAULT;
 	}
 
-	rc = qmi_decode_basic_elem(buf_dst, (char*)buf_src + decoded_bytes,
+	rc = qmi_decode_basic_elem(buf_dst, (void*)((char*)buf_src + decoded_bytes),
 				   string_len, temp_ei->elem_size);
 	*((char *)buf_dst + string_len) = '\0';
 	decoded_bytes += rc;
@@ -654,7 +654,7 @@
 			tlv_pointer = buf_src;
 			QMI_ENCDEC_DECODE_TLV(&tlv_type,
 					      &tlv_len, tlv_pointer);
-			buf_src = (uint8_t*)buf_src + (TLV_TYPE_SIZE + TLV_LEN_SIZE);
+			buf_src = (void*)((char*)buf_src + (TLV_TYPE_SIZE + TLV_LEN_SIZE));
 			decoded_bytes += (TLV_TYPE_SIZE + TLV_LEN_SIZE);
 			temp_ei = find_ei(ei_array, tlv_type);
 			if (!temp_ei && tlv_type < OPTIONAL_TLV_TYPE_START) {
@@ -673,11 +673,11 @@
 			tlv_len = in_buf_len - decoded_bytes;
 		}
 
-		buf_dst = (uint8_t*)out_c_struct + temp_ei->offset;
+		buf_dst = (void*)((char*)out_c_struct + temp_ei->offset);
 		if (temp_ei->data_type == QMI_OPT_FLAG) {
 			memcpy(buf_dst, &opt_flag_value, sizeof(uint8_t));
 			temp_ei = temp_ei + 1;
-			buf_dst = (uint8_t*)out_c_struct + temp_ei->offset;
+			buf_dst = (void*)((char*)out_c_struct + temp_ei->offset);
 		}
 
 		if (temp_ei->data_type == QMI_DATA_LEN) {
@@ -687,7 +687,7 @@
 						   1, data_len_sz);
 			memcpy(buf_dst, &data_len_value, sizeof(uint32_t));
 			temp_ei = temp_ei + 1;
-			buf_dst = (uint8_t*)out_c_struct + temp_ei->offset;
+			buf_dst = (void*)((char*)out_c_struct + temp_ei->offset);
 			tlv_len -= data_len_sz;
 			UPDATE_DECODE_VARIABLES(buf_src, decoded_bytes, rc);
 		}
@@ -777,7 +777,7 @@
 
 	/* Encode message, if we have a message */
 	if (c_struct) {
-		msglen = qmi_encode(ei, (char*)pkt->data + sizeof(*hdr), c_struct,
+		msglen = qmi_encode(ei, (void*)((char*)pkt->data + sizeof(*hdr)), c_struct,
 				    pkt->data_len - sizeof(*hdr), 1);
 		if (msglen < 0)
 			return msglen;
@@ -839,7 +839,7 @@
 	if (txn)
 		*txn = hdr->txn_id;
 
-	return qmi_decode(ei, c_struct, (char*)pkt->data + sizeof(*hdr), pkt->data_len - sizeof(*hdr), 1);
+	return qmi_decode(ei, c_struct, (void*)((char*)pkt->data + sizeof(*hdr)), pkt->data_len - sizeof(*hdr), 1);
 }
 
 /* Common header in all QMI responses */
diff --git a/qcom/qrtr/lib/qrtr.c b/qcom/qrtr/lib/qrtr.c
index 7c1c389..96756ba 100644
--- a/qcom/qrtr/lib/qrtr.c
+++ b/qcom/qrtr/lib/qrtr.c
@@ -52,7 +52,7 @@
 	}
 
 	if (rport != 0) {
-		struct sockaddr_qrtr sq;
+		struct sockaddr_qrtr sq = {};
 
 		sq.sq_family = AF_QIPCRTR;
 		sq.sq_node = 1;
@@ -78,7 +78,7 @@
 
 int qrtr_sendto(int sock, uint32_t node, uint32_t port, const void *data, unsigned int sz)
 {
-	struct sockaddr_qrtr sq;
+	struct sockaddr_qrtr sq = {};
 	int rc;
 
 	sq.sq_family = AF_QIPCRTR;
